1. Field
The disclosed embodiments generally relate to packet-processing systems associated with communications networks. More specifically, the disclosed embodiments relate to a method and an apparatus for pre-classifying packets and determining per-packet attributes for subsequent packet-processing operations.
2. Related Art
Traditional ports in communication networks receive packets and forward them to a main processing unit where they are classified, modified, metered, counted, and forwarded to the next destination. Traditional ports work well in most scenarios. However, there are a few scenarios where more intelligence is needed at the port level. For example, in oversubscribed scenarios, the main processing unit is not able to process all incoming packets, which can lead to packets being dropped. In these scenarios, it is important to be able to drop “best effort” traffic, and not to drop control packets or other important packets.
Moreover, different packets may be directed to different destinations in the packet-processing device. For example, some packets may be destined for the main processing unit and others may be destined for a configuration unit. Hence, it is useful for ports to be able to rapidly and efficiently determine the destination for a packet. These differing destinations are also significant because packets may require different packet attributes depending upon what type of processing device they are targeted for.
Traditional ports in communication network devices typically do not incorporate the above-described functionality or intelligence. Hence, what is needed is a method and an apparatus which provides such functionality at the port level.